#include <gtest/gtest.h>

int sub(int num1, int num2)
{
    return num1 -num2;
}
TEST(测试名称, 减法用例)
{
    ASSERT_EQ(sub(30, 20), 10);
    ASSERT_NE(sub(50, 20), 30);
}
TEST(测试名称, 字符串比较测试)
{
    std::string str("hello");
    ASSERT_EQ(str, "hello");
    EXPECT_EQ(str, "nohello");
    ASSERT_EQ(str, "hello");
    
}


int main(int argc, char* argv[])
{
    //单元测试工具初始化
    testing::InitGoogleTest(&argc, argv);
    //开始单元测试



    return RUN_ALL_TESTS();
}